//计数器仓库类型
export type counterStoreType = {
  count: number;
  increment: () => void;
  decrement: () => void;
  setCount: (count: number) => void;
}
//用户类型
export type userInfoType = {
  name: string;
  age: number;
  address: string;
  phone: string;
} 
//用户仓库类型
export type userStoreType = {
  info: userInfoType | null;
  setInfo: (info: userInfoType) => void;
}


//主仓库类型
export type storeType = counterStoreType & userStoreType ;


//prop类型
export type propsType = {
  num?: number;                 //num可以是number类型
  children?: React.ReactNode;  //children可以是任何ReactNode类型
  onEvent?: () => void;        // onClick可以是函数类型
}


export type resultType<T> = {
  code:number,
  data:T,
  msg:string,
}